#!/usr/bin/python
import re
import MySQLdb
from datetime import datetime
import settings


def executeQuery(query):
	db = MySQLdb.connect(host=settings.DATABASE_HOST, user="root", db="solar", port=3306)
	cursor = db.cursor()
	cursor.execute(query)
	rows = cursor.fetchall()
	cursor.close()
	db.close()
	return rows


